{#include main fluid=true}
  {#style}
   .nav-item {
     padding: .5rem .3rem;
   }
  {/style}  
  {#title}Fired Events{/title}
  {#body}
  <ul class="nav">
    <li class="nav-item">
        <input id="clear" type="submit" class="btn btn-primary btn-sm" value="Refresh"
            onClick="window.location.reload();">
    </li>
    <li class="nav-item">
        <form method="post" enctype="application/x-www-form-urlencoded" class="form-inline">
            <input id="clear" type="submit" class="btn btn-primary btn-sm" value="Clear">
        </form>
    </li>
    <li class="nav-item">
        <form method="post" enctype="application/x-www-form-urlencoded" class="form-inline">
            <input id="skipContextsCheck" type="checkbox" class="form-check-input" disabled{#if info:eventsMonitor.skipContextEvents} checked{/if}>
      <label for="skipContextsCheck">Skip context lifecycle events</label>
      <input type="hidden" name="action" value="skipContext">
      &nbsp;
      <input id="toggle" type="submit" class="btn btn-primary btn-sm" value="Toggle">
    </form>
    </li>
  </ul>
  <table class="table table-striped">
   <thead class="thead-dark">
    <tr>
      <th scope="col">Timestamp <i class="fas fa-caret-down"></i></th>
      <th scope="col">Event Type</th>
      <th scope="col">Qualifiers</th>
    </tr>
   </thead>
   <tbody>
    {#for event in info:eventsMonitor.lastEvents.orEmpty}
    <tr>
      <td>
       {event.timestamp}
      </td>
      <td>
        {event.type}
      </td>
      <td>
       {#when event.qualifiers.size}
         {#is 1}
            <code>{event.qualifiers.iterator.next}</code>
         {#is > 1}
            <ul>
            {#for q in event.qualifiers}
              <li>{q}</li>
            {/for}
            </ul>
       {/when}
       </td>
      </tr>
    {/for}
   </tbody>
  </table>
 {/body}
{/include}
